<html>
<?php
	include_once("ClsSebent/config.php");		
	//$_SESSION['SITE_ID']=101;
	$sql="SELECT * FROM site_home WHERE id='".$_SESSION['SITE_ID']."'";
	$sql1="SELECT * FROM site_page WHERE id='$pid' AND site_id='".$_SESSION['SITE_ID']."'";
	//echo $sql1;
	$result = mysql_query($sql);
	$result1 = mysql_query($sql1);
	$num=1;
	if($data1=mysql_fetch_array($result1))$flag=1;
	if($data=mysql_fetch_array($result)){
?>
<head>
<title><?php if($flag==1)echo stripslashes($data1["meta_title"]);else echo stripslashes($data["meta_title"]);?></title>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
<meta name="keywords" content="<?php if($flag==1)echo stripslashes($data1["meta_keywords"]); else echo $data["meta_keywords"];?>">
<meta name="description" content="<?php if($flag==1)echo stripslashes($data1["meta_description"]); else echo $data["meta_description"];?>">
<link href="style.css" rel="stylesheet" type="text/css">
</head>
<style>
.body {
	background-color: #<?php echo $data["page_bg_color"]; ?>;
}
.body,td,th {
	font-size: 14px;
	color: #<?php echo $data["page_tdtext_color"];?>;
	font-weight: bold;
}
a:link {
	color: #<?php echo $data["page_link_text_color"]; ?>;
}
a:visited {
	color: #<?php echo $data["page_link_visited_color"]; ?>;
}
a:hover {
	color: #<?php echo $data["page_link_rollover_color"]; ?>;
}
a:active {
	color: #<?php echo $data["page_link_rollover_color"]; ?>;
}
.h1 {
	font-weight: bold;
	font-size: 24px;
	color: #<?php echo $data["page_text_color"]; ?>;
}
.h2 {
	font-weight: bold;
}
.h3 {
	font-weight: bold;
}
.h4 {
	font-weight: bold;
}
.h5 {
	font-weight: bold;
}
.h6 {
	font-weight: bold;
}
.h2 {
	font-size: 16px;
	color: #<?php echo $data["page_text_color"]; ?>;
}
.style4 {font-size: 14px}
.style7 {
	font-family: Dauphin;
	font-size: 24px;
	color: #<?php echo $data["page_text_color"]; ?>;
}
.style9 {color: #FFFFFF}
.style10 {font-size: 26px}
.style13 {font-size: 36px}
h3 {
	font-size: 16px;
	color: #<?php echo $data["page_text_color"]; ?>;
}
.style8 {font-size: 24px}
.style1 {font-size: 24px;
	font-weight: bold;
	font-style: italic;
	color: #<?php echo $data["page_text_color"]; ?>;
}
</style><body class="body">
<!-- We Offer cd duplication, cd replication, cd rom duplication, cd rom replication, cd duplication services, cheap cd duplication, cd dvd replication, cd business card replication, cd replication services, bulk cd replication Services. Start your own record label. -->
<CENTER><H2><?php if($pid==0){ echo "Under Construction!<BR><BR><a href='#' onclick='javascript:history.back()'>Go Back</a>"; exit; } ?></H2></CENTER>
<table width="100%"  border="0" summary="CD Duplication">
  <tr>
    <th height="698" scope="col"><table width="800" height="696" border="5" align="center" bordercolor="#<?php echo $data["bdr_color1"];?>" summary="cd replication">
      <tr>
        <th height="682" scope="col"><table width="100%"  border="2" align="center" bordercolor="#<?php echo $data["bdr_color2"];?>">
          <tr>
            <th background='photos/header/<?php echo  $_SESSION['SITE_ID'] . "_" . $data["page_bg_image"]; ?>' alt='<?php echo $data["page_bg_image_alt"];?>' scope="col"><table width="100%"  border="0">
                <tr>
                  <th width="21%" height="153" scope="col"><?php
		  if($data["logo"] !=""){ ?>
                  <img src="logos/<?php echo $_SESSION['SITE_ID']."_frontlogo.jpg";//echo $_SESSION['SITE_ID'] . "_" . $data["logo"]; ?>" alt="<?php $log=$data["logo_alt"]; $log=stripslashes($log); $log=str_replace('"','&quot;',$log); echo $log; ?>" width="150" height="149" align="middle"><?php
		  }
		  ?></th>
                  <th width="54%" scope="col">
					  <p align="center"><font face="Arial" size="6"><?php echo nl2br($data["company_name"]); ?></font></p>
					  <p align="center"><font face="Arial" size="2"><?php echo $data["slogan"]; ?></font></td>
				  </th>
                  <th width="25%" scope="col"><?php echo nl2br ($data["contact_info"]); ?></th>
                </tr>
            </table></th>
          </tr>
          <tr>
            <td height="507"><table width="100%"  border="2" bordercolor="<?php echo $data["bdr_color3"];?>">
                <tr>
                  <th width="21%" height="495" align="center" valign="top" background='photos/navbar/<?php echo  $_SESSION['SITE_ID'] . "_" . $data["page_bg_image"]; ?>' scope="col"><table width="100%" height="489"  border="0">
                      <tr>
                        <th valign="top" scope="col" align='left'><table width="100%" border="0" summary="Navbar Table">
					<?php
						$sql="SELECT * FROM site_navbar WHERE site_id='".$_SESSION['SITE_ID']."' AND link_active='Y' AND link_parent=0 ORDER BY link_position, link_text";
						$nav_res = mysql_query($sql);
						while($nav_data=mysql_fetch_array($nav_res)){
							if($nav_data["link_page"] == 10){
								?><tr><td><a target="_self" class="style4" href='shop.php?site_id=<?php echo $_SESSION['SITE_ID']; ?>'><?php
								echo $nav_data["link_text"];
								?></a></td></tr><?php
							}
							else{
								?><tr><td><a target="_self" class="style4" href='page.php?site_id=<?php echo $_SESSION['SITE_ID']; ?>&pid=<?php echo $nav_data["link_page"]; ?>'><?php
								echo $nav_data["link_text"];
								?></a></td></tr><?php

								$sql="SELECT * FROM site_navbar WHERE site_id='".$_SESSION['SITE_ID']."' AND link_active='Y' AND link_parent=" . $nav_data["id"] . " ORDER BY link_position, link_text";

								$nav_res2 = mysql_query($sql);
								while($nav_data2=mysql_fetch_array($nav_res2)){
									?><tr><td style="padding-left:10px"><a target="_self" class="style4" href='page.php?site_id=<?php echo $_SESSION['SITE_ID']; ?>&pid=<?php echo $nav_data2["link_page"]; ?>'><?php
									echo $nav_data2["link_text"];
									?></a></td></tr><?php
								}
							}
						}
					?>                            
                            <tr>
                              <td height="19" align="left"><!--<a href="cart_page.php?site_id=<?php echo $_SESSION['SITE_ID']; ?>&pid=10&cat=none&fst=0&lst=8">Shopping Cart</a>--></td>
                            </tr>
                        </table></th>
                      </tr>
                  </table></th>
                  <th width="79%" align="center" valign="top" scope="col"><table width="100%"  border="0">
                      <tr>
                        <th width="2%" height="103" scope="col">&nbsp;</th>
                        <th width="96%" align="center" valign="top" scope="col"><table width="100%"  border="0">
                            <tr>
                              <td height="400" valign=top align=center>

							  <?php
									$sql="SELECT * FROM site_product WHERE product_id='$pid'";
									$page_res = mysql_query($sql);
									if($row=mysql_fetch_array($page_res)){
										$pro_id=$row["product_id"];
										$product_title=$row["product_title"];
										$price=$row["price"];
										$profit_pct=$row["profit_pct"];
										$tax_pct=$row["tax_pct"];
										$shipping_amt=$row["shipping_amt"];
									}

									$sql="SELECT * FROM product_master WHERE id='$pid'";

									$result_pro_master = mysql_query($sql);
									if($row_pro_master=mysql_fetch_array($result_pro_master)){
										$product_desc=$row_pro_master["product_desc"];
										$product_img=$row_pro_master["product_img"];
										$product_img_alt=$row_pro_master["product_img_alt"];
										$product_price=$row_pro_master["product_price"];
									}
										?>										
										<table border="1" cellpadding="0" cellspacing="0" style="border-collapse: collapse;" bordercolor="#111111" width="300" id="AutoNumber1">
										  <caption>
										  <h2><U><FONT COLOR="#<?php echo $data["page_title_color"]; ?>"><?php echo $product_title; ?></font></U></h2>
										  </caption>
										  <tr>
											<td width="177" align=left><FONT COLOR="#<?php echo $data["page_title_color"]; ?>">PRICE</font></td>
											<td width="19"><FONT COLOR="#<?php echo $data["page_title_color"]; ?>">:</font></td>
											<td width="200" align=right><FONT COLOR="#<?php echo $data["page_text_color"]; ?>">$<?php echo $price; ?></font></td>
										  </tr>
										  <tr>
											<td width="177" align=left><FONT COLOR="#<?php echo $data["page_title_color"]; ?>">TAX</font></td>
											<td width="19"><FONT COLOR="#<?php echo $data["page_title_color"]; ?>">:</font></td>
											<td width="200" align=right><FONT COLOR="#<?php echo $data["page_text_color"]; ?>">$<?php echo ($price * $tax_pct/100); ?></font></td>
										  </tr>
										  <tr>
											<td width="177" align=left><FONT COLOR="#<?php echo $data["page_title_color"]; ?>">SHIPPING</font></td>
											<td width="19"><FONT COLOR="#<?php echo $data["page_title_color"]; ?>">:</font></td>
											<td width="200" align=right><FONT COLOR="#<?php echo $data["page_text_color"]; ?>">$<?php echo $shipping_amt; ?></font></td>
										  </tr>
										  <tr>
											<td width="177" align=left><BR><BR><B><FONT COLOR="#<?php echo $data["page_title_color"]; ?>">TOTAL</font></B></td>
											<td width="19"><BR><BR><FONT COLOR="#<?php echo $data["page_title_color"]; ?>">:</font></td>
											<td width="200" align=right><BR><BR><B><FONT COLOR="#<?php echo $data["page_text_color"]; ?>">$<?php $total=$price + ($price * $tax_pct/100) + $shipping_amt; echo $total; ?></font></B> 
											</td>
										  </tr>

										</table><P>
										<a href="https://www.paypal.com/xclick/business=<?php echo $data['paypal_id']; ?>&item_name=<?php echo $product_title; ?>&item_number=<?php echo $pid; ?>&amount=<?php echo money_format('%.2n', ($price * (100+$tax_pct)/100) + $shipping_amt); ?>&image_url=http://king.hostingcorp.biz/logos/<?php echo $_SESSION['SITE_ID'] . "_" . $logo; ?>&shipping=<?php echo $shipping_amt; ?>&return=http://king.hostingcorp.biz/&cancel_return=http://king.hostingcorp.biz&currency_code=USD" target="_n1">			<img src="https://www.paypalobjects.com/en_US/i/logo/logo-xclick2.gif"></a>										
							&nbsp;</td>
                            </tr>
                            <tr>
                              <td><h3 align="center"><?php echo $data["copyright"]; ?></h3></td>
                            </tr>
                            <!-- <tr>
                              <td height="21"><h3 align="center">Report any problems with web site to <a href="/Templates/CS@KingOfEnterprise.com">Webmaster@KingOfEnterprise.com</a></h3></td>
                            </tr> -->
                        </table></th>
                        <th width="2%" scope="col">&nbsp;</th>
                      </tr>
                  </table></th>
                </tr>
            </table></td>
          </tr>
        </table></th>
      </tr>
    </table></th>
  </tr>
</table>
</body>
<?php
	}
?>
</html>